package pos.Configuration;

import pos.ControlCenter;
import pos.ICommand;
import pos.MainMenu.MainMenuController;
import pos.Profile;

/**
 *
 * @author plus
 */
public class CommandSave implements ICommand {
    private Profile Receiver;
    public CommandSave(Profile Receiver) {
        this.Receiver = Receiver;
    }
    public Object execute(Object Param) {
        Receiver.save();
        ControlCenter.setCurrentProfile(Receiver);
        ControlCenter.setCurrentMode(new MainMenuController());
        return null;
    }
}
